<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<%
    String path = request.getContextPath();
    String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
<!DOCTYPE html>
<html>
<head>
    <base href="<%=basePath %>">
    <meta charset="utf-8">
    <title>上线项目展示</title>
    <meta name="renderer" content="webkit">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    <link rel="stylesheet" href="js/layui/css/layui.css"  media="all">
</head>
<body>

<div >
    <table  class="layui-table" id="test1" >

    </table>
</div>

<script src="js/layui/layui.js" charset="utf-8"></script>
<script>
    layui.use(['table' ,'laypage'], function(){
        var table = layui.table;
        table.render({
            elem: '#test1'
            ,height: 300
            ,page:false
            ,url: 'item/itemDetail?id='+<%=request.getParameter("id")%> //数据接口
            ,cols: [[ //表头
                // {type:'checkbox', fixed: 'left'}
                {field: 'id', title: 'ID', width:50, sort: true, fixed: true}
                ,{field: 'title', title: '项目名称', width:150}
                ,{field: 'userNicename', title: '发起人', width:100}
                ,{field: 'mobile', title: '联系电话', width:150}
                ,{field: 'brief', title: '项目简介', width:200}
                ,{field: 'description', title: '项目内容', width:200}
                ,{field: 'itemreturns', title: '回报内容', width:200}
                ,{field: 'targetAmount', title: '目标金额', width: 100}
                ,{field: 'perMoney', title: '起投金额', width:100, }
                ,{field: 'actAmount', title: '已筹金额', width:100}
                ,{field: 'beginTime', title: '上线时间', width: 200}
                ,{field: 'endTime', title: '结束时间', width:200, }
                ,{field: 'zcDays', title: '众筹天数', width:80}
                ,{field: 'isBeyond', title: '是否可以超额', width:80}
                ,{field: 'isRecommend', title: '是否推荐', width: 80}
                ,{field: 'isEffect', title: '是否成功', width:80, }
                ,{field: 'location', title: '项目位置', width:150}
                ,{field: 'views', title: '浏览量', width:80}
                ,{field: 'doLike', title: '点赞数', width: 80}
                ,{field: 'createtime', title: '创建时间', width:200, }
                ,{field: 'createby', title: '创建人', width:100}
                ,{field: 'updatetime', title: '更新时间', width:200}
                ,{field: 'updateby', title: '更新人', width:100}
            ]]
        });
    })

</script>

</body>
</html>